<template>
  <div class="search-container">
    <div class="search-wrapper">
      <div class="icon"
           @click="searchList">
        <!-- <svg-icon icon-class="icon_search"
                  class="icon_search" /> -->
        <img class="img_search" src="https://img.wifenxiao.com/h5-wfx/images/common/search-icon.png" mode="scaleToFill"/>
      </div>
      <input @confirm="searchList"
             v-model.trim="keyword"
             type="text"
             placeholder="订单编号" />
    </div>
  </div>
</template>

<script>
import Vue from 'vue'
export default Vue.extend({
  name: 'index',
  components: {},
  data() {
    return {
      keyword: ''
    }
  },
  methods: {
    searchList() {
      this.$emit('searchOrder', this.keyword)
    }
  }
})
</script>

<style lang="scss">
@import "../../../../../../styles/mixin";
.search-container {
  padding: 24px 25px;
  background: #fff;
}
.search-wrapper {
  position: relative;
  width: 100%;
  height: 72px;
  border-radius: 66px;
  font-size: 0;
  background: #F7F7F7;
  .icon {
    position:absolute;
    width:32px;
    height:32px;
    left:28px;
    top: 50%;
    transform: translateY(-50%);
    color:#999999;
    font-size: 28px;
    font-weight: bold;
    .icon_search{
      width:32px;
      height:32px;
    }
  }
  .img_search{
    display:block;
    width: 28px;
    height: 28px;
  }
  @include placeColor(#999);
  input {
    display: inline-block;
    width: 100%;
    height: 72px;
    font-size: 24px;
    padding: 15px 70px;
    border: 0;
    background: transparent;
  }
}
</style>